package org.csu.sei.entity.DTO;

import org.csu.sei.entity.User;

public class UserDTO {
    private String username;
    private String password;
    private String email;
    private String phone;
    private String question;
    private String answer;
    private int role;

    public UserDTO(User user){
        this.username = user.getUsername();
        this.password = user.getPassword();
        this.email = user.getEmail();
        this.phone = user.getPhone();
        this.answer = user.getAnswer();
        this.question = user.getQuestion();
        this.role = user.getRole();
    }

    public static UserDTO returnUser(User user){
        return new UserDTO(user);
    }
}
